<#import "/layout.html" as c>
    <#import "/list_layout.html" as list>
        <#assign alertList = []/>
        <@c.html title="Index">
        <!================== 开始页面级CSS调用 ================== &ndash;&gt;-->
        <link href="${pluginsRoot}bootstrap-wizard/css/bwizard.min.css" rel="stylesheet"/>
        <!-- 日历控件 -->
        <link href="${pluginsRoot}/jquery.dtGrid/dependents/datePicker/skin/WdatePicker.css" rel="stylesheet"/>
        <link href="${pluginsRoot}/jquery.dtGrid/dependents/datePicker/skin/default/datepicker.css" rel="stylesheet"/>
        <!-- ================== 结束页面级CSS调用 ================== &ndash;&gt;-->
        <@list.html title="用户风控参数" subTitle="用户风控参数" alertList=alertList permi="sys:user:risk:save" addBtn=true searchHint="请输入用户名称进行搜索">


        <@shiro.hasPermission name="sys:user:risk:edit">
        <input type="hidden" id="riskEdit" value="1"/>
        </@shiro.hasPermission>


<!-- 开始新增产品模态窗口 -->
<div class="modal fade" id="addModal" tabindex="-1" role="dialog">
    <div class="modal-dialog modal-lg">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                <h4 class="modal-title"> 新增风控参数 <a class="btn btn-info btn-xs m-l-5" role="button" data-toggle="collapse" href="#OperationTips" aria-expanded="true" title="操作提示"><i class="fa fa-exclamation"></i> 提示 </a> </h4>
            </div>
            <div class="modal-body">
                <ul class="collapse in text-info p-b-10 p-l-15" role="tabpanel" id="OperationTips">
                    <li>请根据表单提示信息正确输入选择。</li>
                </ul>
                <form class="form-horizontal form-bordered p-0" action="${adminRoot}user/risk/json/add" id="addForm" method="post" autocomplete="off" data-parsley-validate="true">
                    <div class="form-group">
                        <label class="control-label col-md-2 col-sm-3">选择用户&nbsp;:</label>
                        <div class="col-md-9 col-sm-8">
                            <a data-target='#userModal' class='btn btn-sm btn-primary m-r-10' data-toggle='modal'><i class='fa fa-plus'>&nbsp;选择用户</i>&nbsp;</a>
                            <label  id="chooseUserAdd"></label>
                            <input type="hidden"  name="userId" value="">
                        </div>
                    </div>
                    <div class=""form-group">
                        <label class="control-label col-md-2 col-sm-3">选择品种<i class="f-s-14 text-danger">*</i>&nbsp;: </label>
                        <div class="col-md-9 col-sm-8">
                           <select name="commoId" class="form-control" data-parsley-required="true" >
                               <option value ="">--请选择--</option>
                                <#if commoList??>
                                  <#list commoList as item>
                                     <option value ="${item.id}">${item.name!} ${item.code!}</option>
                                  </#list>
                                </#if>
                           </select>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2 col-sm-3">交易综合费<i class="f-s-14 text-danger">*</i>&nbsp;: </label>
                        <div class="col-md-9 col-sm-8">
                            <input type="text" name="fee" class="form-control" placeholder="请输入费用" maxlength="10" autocomplete="off" data-tip="tooltip" data-placement="auto" data-original-title="必填项，只能填写数字且输入内容小于10个字符。" data-parsley-required="true" data-parsley-length="[1, 10]"/>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2 col-sm-3">过夜费&nbsp;:<i class="f-s-14 text-danger">*</i>&nbsp;:</label>
                        <div class="col-md-9 col-sm-8">
                            <input type="text" name="overnightFee" class="form-control" placeholder="请输入过夜费" maxlength="10" autocomplete="off" data-tip="tooltip" data-placement="auto" data-original-title="必填项，只能填写数字且输入内容小于10个字符。" data-parsley-required="true" data-parsley-length="[1, 10]"/>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="control-label col-md-2 col-sm-3">状态&nbsp;*: </label>
                        <div class="col-md-9 col-sm-8">
                            <input type="checkbox" class="status" autocomplete="off"
                                   data-input-name="status"
                                   data-size="small"
                                   data-on-color="primary"
                                   data-on-text="正常"
                                   data-off-text="冻结"
                                   data-input-true="1"
                                   data-input-false="2"
                                   checked/>
                        </div>
                    </div>

                </form>
            </div>
            <div class="modal-footer"><a href="javascript:;" class="btn btn-white" data-dismiss="modal">放弃操作</a><a href="javascript:;" class="btn btn-success" data-loading-text="Loading..." nc-ajax-submit-target="addForm" nc-ajax-submit>确认提交</a></div>
        </div>
    </div>
</div>
<!-- 结束新增产品模态窗口 -->

<!--&lt;!&ndash; 开始编辑风控参数模态窗口 &ndash;&gt;-->
    <div class="modal fade" id="editModal" tabindex="-1" role="dialog">
        <div class="modal-dialog modal-lg">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                    <h4 class="modal-title"> 编辑用户风控参数 <a class="btn btn-info btn-xs m-l-5" role="button" data-toggle="collapse" href="#OperationTipsEdit" aria-expanded="true" title="操作提示"><i class="fa fa-exclamation"></i> 提示 </a> </h4>
                </div>
                <div class="modal-body">
                    <form class="form-horizontal form-bordered p-0" action="${adminRoot}user/risk/json/edit" id="editForm" method="post" autocomplete="off" data-parsley-validate="true">
                        <input type="hidden" name="id" value="">
                        <div class="form-group">
                            <label class="control-label col-md-2 col-sm-3">用户名&nbsp;:<i class="f-s-14 text-danger">*</i>&nbsp;:</label>
                            <div class="col-md-9 col-sm-8">
                                <input type="text" name="userName" class="form-control"  autocomplete="off" data-tip="tooltip" data-placement="auto" readonly/>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="control-label col-md-2 col-sm-3">品种&nbsp;:<i class="f-s-14 text-danger">*</i>&nbsp;:</label>
                            <div class="col-md-9 col-sm-8">
                                <input type="text" name="name" class="form-control"  autocomplete="off" data-tip="tooltip" data-placement="auto" readonly/>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="control-label col-md-2 col-sm-3">交易综合费<i class="f-s-14 text-danger">*</i>&nbsp;:</label>
                            <div class="col-md-9 col-sm-8">
                                <input type="text" name="fee" class="form-control" placeholder="请输入交易综合费" maxlength="10" autocomplete="off" data-tip="tooltip" data-placement="auto" data-original-title="必填项，只能填写数字且输入内容小于10个字符。"  data-parsley-required="true" data-parsley-length="[1, 10]"/>
                            </div>
                        </div>
                        <div class="form-group">
                            <label class="control-label col-md-2 col-sm-3">过夜费<i class="f-s-14 text-danger">*</i>&nbsp;:</label>
                            <div class="col-md-9 col-sm-8">
                                <input type="text" name="overnightFee" class="form-control" placeholder="请输入过夜费" maxlength="10" autocomplete="off" data-tip="tooltip" data-placement="auto" data-original-title="必填项，只能填写数字且输入内容小于10个字符。"  data-parsley-required="true" data-parsley-length="[1, 10]"/>
                            </div>
                        </div>

                        <div class="form-group">
                            <label class="control-label col-md-2 col-sm-3">是否显示&nbsp;*: </label>
                            <div class="col-md-9 col-sm-8">
                                <input type="checkbox" class="status" autocomplete="off"
                                       data-input-name="status"
                                       data-size="small"
                                       data-on-color="primary"
                                       data-on-text="正常"
                                       data-off-text="冻结"
                                       data-input-true="1"
                                       data-input-false="2"
                                       checked/>
                            </div>
                        </div>
                    </form>
                    <!-- 结束设置模块-->
                </div>
                <div class="modal-footer"><a href="javascript:;" class="btn btn-white" data-dismiss="modal">放弃操作</a><a href="javascript:;" class="btn btn-success" data-loading-text="Loading..." nc-ajax-submit-target="editForm" nc-ajax-submit>确认提交</a></div>
            </div>
        </div>
    </div>
<!-- 结束编辑风控参数模态窗口 -->


    <!--开始选择模态窗口 -->
    <div class="modal fade" id="userModal" tabindex="-1" role="dialog">
        <div class="modal-dialog modal-lg">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
                    <h4 class="modal-title">用户列表<a class="btn btn-info btn-xs m-l-10" role="button" data-toggle="collapse" href="<#--#OperationTips-->" aria-expanded="false" title="操作提示"><i class="fa fa-exclamation"></i>&nbsp;提示</a></h4>
                </div>
                <div class="modal-body">
                    <div id="dtGridContainerUser" class="dt-grid-container"></div>
                    <div id="dtGridToolBarContainerUser" class="dt-grid-toolbar-container"></div>
                </div>
            </div>
        </div>
    </div>
    <!--结束选择模态窗口-->

    </@list.html>
    <!-- ================== 开始页面级JavaScrip调用 ================== &ndash;&gt;-->
    <script src="${pluginsRoot}bootstrap-wizard/js/bwizard.js"></script>
    <!-- 表单checkbox项 -->
    <script src="${pluginsRoot}bootstrap-switch/bootstrap-switch.min.js"></script>
    <!-- 日历控件 -->
    <script src="${pluginsRoot}/jquery.dtGrid/dependents/datePicker/WdatePicker.js" defer="defer"></script>
    <script src="${jsRoot}user/user_commo_risk.handle.js"></script>
    <!-- ================== 结束页面级JavaScrip调用 ================== -->
</@c.html>